package com.fenxiangtech.mall.dao;

import com.fenxiangtech.mall.model.Product;
import com.fenxiangtech.mall.model.qc.ProductQC;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
@Repository
public interface ProductDAO{

    int insertProduct(Product product);

    int updateProduct(Product product);

    List<Product> listProduct(ProductQC product);

    Long countProduct(ProductQC product);

    int insertBatch(@Param("list") List<Product> products);

    int deleteProductById(Long id);

}